﻿using System.ComponentModel.DataAnnotations;

namespace OperationPlugins.Validators.DataAnnotations
{
    public interface IUsePluginValidatorsAttributeResolveBranch
    {
        /// <summary>
        /// Resolves the current branch.
        /// </summary>
        /// <remarks>
        /// The default value is <see cref="Branches.Any"/>.
        /// </remarks>
        /// <param name="value">The value to validate.</param>
        /// <param name="validationContext">Describes the context in which a data annotations validation check is performed.</param>
        /// <returns>The current branch.</returns>
        BranchId ResolveBranch(object value, ValidationContext validationContext);
    }
}